Tighten the 'const' screws a little more to help Alex along.
authorrobertl <robertl@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Thu, 19 Sep 2002 16:00:12 +0000 (16:00 +0000)
committerrobertl <robertl@f51c46e8-681c-474f-0cfe-069cfd0219fb>
Thu, 19 Sep 2002 16:00:12 +0000 (16:00 +0000)
13 files changed:
gpsbabel/defs.h
gpsbabel/geo.c
gpsbabel/gpsman.c
gpsbabel/gpsutil.c
gpsbabel/gpx.c
gpsbabel/holux.c
gpsbabel/magproto.c
gpsbabel/mapsend.c
gpsbabel/mapsource.c
gpsbabel/pcx.c
gpsbabel/tiger.c
gpsbabel/util.c
gpsbabel/waypt.c

index 128abe1ae3c0cf7ae9ed9ac80436153e1ece5d5f..71341364bc31889282541b331e91297d02c42788 100644 (file)
@@ -87,7 +87,7 @@ typedef void (*ff_deinit) (void);
 typedef void (*ff_read) (void);
 typedef void (*ff_write) (void);
 
-typedef void (*waypt_cb) (waypoint *);
+typedef void (*waypt_cb) (const waypoint *);
 void waypt_add (waypoint *);
 void route_add (waypoint *);
 void waypt_disp_all(waypt_cb);
@@ -109,11 +109,11 @@ typedef struct ff_vecs {
 
 void waypt_init(void);
 void route_init(void);
-void waypt_disp(waypoint *);
+void waypt_disp(const waypoint *);
 void fatal(const char *, ...);
 ff_vecs_t *find_vec(char *);
 void disp_vecs(void);
-void printposn(coord *c, int is_lat);
+void printposn(const coord *c, int is_lat);
 
 void *xcalloc(size_t nmemb, size_t size);
 void *xmalloc(size_t size);
index 1333c20f855bd537a22f15d875f36c4e50f64ce4..db6deb3b7ac3eb9b9f141e0817be21252ba10cc9 100644 (file)
@@ -186,7 +186,7 @@ geo_read(void)
 }
 
 static void
-geo_waypt_pr(waypoint *waypointp)
+geo_waypt_pr(const waypoint *waypointp)
 {
        fprintf(ofd, "<waypoint>\n");
        fprintf(ofd, "<name id=\"%s\">", waypointp->shortname);
index 797fe4aa4ffaa2814d19a1901b5233add5790225..fbabe1ebc209113ad87571ebec4a868003a0ff81 100644 (file)
@@ -57,7 +57,7 @@ gpsman_wr_deinit(void)
 }
 
 static void
-gpsman_disp(waypoint *waypointp)
+gpsman_disp(const waypoint *waypointp)
 {
        fprintf(out_file, "%-8.8s\t%s\t", 
                waypointp->shortname, waypointp->description);
index abae0c85a52a88e119f5156b71516ac68704fba7..79103d76388f7580dee43a30c4bf9f832323ba79 100644 (file)
@@ -77,7 +77,7 @@ data_read(void)
 }
 
 static void
-gpsutil_disp(waypoint *wpt)
+gpsutil_disp(const waypoint *wpt)
 {
        double lon,lat;
        const char *icon_token;
index 97c417725b0decf41707053d6a377f27967d73a2..0f03c110deab66e8b3166d65b717d836bbc38553 100644 (file)
@@ -205,7 +205,7 @@ gpx_read(void)
 }
 
 static void
-gpx_waypt_pr(waypoint *waypointp)
+gpx_waypt_pr(const waypoint *waypointp)
 {
 
        fprintf(ofd, "<wpt lat=\"%lf\" lon=\"%lf\">\n",
index 0bc0bd1e610a15a77d3d80991707faf59939d86f..9d87f0127b557bd12a85ece3334ce4e3b3ce6270 100644 (file)
@@ -171,7 +171,7 @@ char *mknshort (char *stIn,unsigned int sLen)
 
 
 
-static void gpsutil_disp(waypoint *wpt)
+static void holux_disp(const waypoint *wpt)
 {
        double lon,lat;
        struct tm *tm;
@@ -266,7 +266,7 @@ static void data_write(void)
         ((RTEHDR *)&HxWFile[ROUTESTART])->used[sCount] = 0; 
 
 
-    waypt_disp_all(gpsutil_disp);
+    waypt_disp_all(holux_disp);
    
 
        file_out = fopen(fOutname, "wb");
index 86f7d92116c03e3a012408e7a67598582ccaef0a..9bad44098d8e46b96b1af0bb6c62ddad5fd127e6 100644 (file)
@@ -716,7 +716,7 @@ mag_readwpt(void)
 
 static
 void
-mag_waypt_pr(waypoint *waypointp)
+mag_waypt_pr(const waypoint *waypointp)
 {
        double lon, lat;
        double ilon, ilat;
index 7d9d3ac41b840012b0d0ecc1974df93790c24b33..2064f3abfc186c3ee1b6f2c069e6b93bbfb275ac 100644 (file)
@@ -236,7 +236,7 @@ mapsend_read(void)
 }
 
 static void
-mapsend_waypt_pr(waypoint *waypointp)
+mapsend_waypt_pr(const waypoint *waypointp)
 {
        int n;
        unsigned char c;
index fe675a5960d65ed1c214202b21be68ad2e847b6f..3db7d2d1e1432b1c304c4936024b747a6b32108b 100644 (file)
@@ -96,7 +96,7 @@ mapsource_read(void)
 }
 
 static void
-mapsource_waypt_pr(waypoint *waypointp)
+mapsource_waypt_pr(const waypoint *waypointp)
 {
        char tbuf[1024];
        char *tp = tbuf;
index 9b5b347c5e834caf966ee286f2b0fad7e57c1c88..039e1b2ef61a21333f28181d98c132aa6a113f9b 100644 (file)
@@ -94,7 +94,7 @@ data_read(void)
 }
 
 static void
-gpsutil_disp(waypoint *wpt)
+gpsutil_disp(const waypoint *wpt)
 {
        double lon,lat;
        signed int ilon, ilat;
index 34a5196c1d3a69686ffcfe7d23787fbe933d903f..4100a5290d08f3141c209b2932e018ecaec06133 100644 (file)
@@ -91,7 +91,7 @@ abort();
 }
 
 static void
-gpsutil_disp(waypoint *wpt)
+gpsutil_disp(const waypoint *wpt)
 {
        fprintf(file_out, "%f,%f:redpin:%s\n", 
                wpt->position.longitude.degrees,
index 66e729b0655c7ef4e2644110015e897a85a74f7f..08401650b2bd2495fc354974a65136a5178991e9 100644 (file)
@@ -69,7 +69,7 @@ mkposn(const char *string)
 }
 
 void
-printposn(coord *c, int is_lat)
+printposn(const coord *c, int is_lat)
 {
        char d;
        if (is_lat) {
index ce77d7a42971566dae6e967adb32da0c9c1fa831..5a04006f5f4971e3e49b625883a7a1a4dbc2c816 100644 (file)
@@ -45,7 +45,7 @@ waypt_count(void)
 }
 
 void
-waypt_disp(waypoint *wpt)
+waypt_disp(const waypoint *wpt)
 {
        if (wpt->creation_time) {
                printf("%s ", ctime(&wpt->creation_time));